<template>
    <div class="mainLeft">
        <slot></slot>
    </div>
</template>

<script>
export default {
    name:'mainLeft',
    data(){
        return{
            getchildIsOpen:[],
            childOpen:[]
        }
    },
    props:{
        openItem:{
            type:Array,
            default:[]
        }
    },
    mounted(){
            
            this.$children.forEach((item1,index) => {
            this.openItem.forEach((item2,index) => {
                if(item1.name == item2){
                    item1.active = 'true' 
                    this.childOpen.push({'name':item1.name,'active':item1.active})
                     }
                })
            })
        
       

        //console.log(this.childOpen)
        
    }
}
</script>

<style scoped>

</style>